//
//  ScrollAddImageView.h
//  TruckSelling
//
//  Created by enghou on 2017/9/1.
//  Copyright © 2017年 xyxorigation. All rights reserved.
//
//  实现

#import <UIKit/UIKit.h>
#import "MediaItemModel.h"
@class ScrollAddImageView;

@protocol ShowImagePicker <NSObject>

-(void)showPicker;

@optional
-(void)showBigImageWithCurrentIndex:(NSInteger)cindex imageSource:(NSArray *)source;



@end

@interface ScrollAddImageView : UIView


@property(nonatomic,strong)NSMutableArray <MediaItemModel *>*deletedFiles;

@property(nonatomic,assign)id<ShowImagePicker>delegate;

@property(nonatomic,assign,readonly)NSInteger maxNum;

@property(nonatomic,strong,readonly)NSMutableArray *objects;

-(UIImageView *)imageViewForIndex:(NSInteger)index;

-(void)feedImage:(MediaItemModel *)image;

-(void)feedImages:(NSArray <MediaItemModel *>*)images;

-(instancetype)initWithFrame:(CGRect)frame maxNum:(NSInteger)maxNum;

-(void)clearImages;

-(NSArray *)imageArray;

@property(nonatomic,strong)NSMutableArray *webImageFileIDs;//来存网络图片的ID

@property(nonatomic,strong)NSMutableArray *source;

@end
